//
// Created by Administrator on 2024/7/9.
//

#include <iostream>
using namespace std;

int sum(int x)
{
    if (x<1)
        return x;
    return x+sum(x-1);
}

int main()
{
    int n=10;
    cout<<sum(n)<<endl;
    return 0;
}